package ltd.hxya.novel.book.controller;


import feign.Body;
import ltd.hxya.novel.book.entity.BookContent;
import ltd.hxya.novel.book.entity.BookIndex;
import ltd.hxya.novel.book.service.IBookContentService;
import ltd.hxya.novel.book.vo.BookContentVo;
import ltd.hxya.novel.common.bean.Result;
import ltd.hxya.novel.common.to.book.BookChapterTo;
import ltd.hxya.novel.common.utils.BaseUtils;
import ltd.hxya.novel.common.vo.BookContentParam;
import ltd.hxya.novel.common.vo.BookIndexVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * <p>
 * 小说内容表 前端控制器
 * </p>
 *
 * @author hxya
 * @since 2022-09-13
 */
@RestController
@RequestMapping("/book/bookContent")
public class BookContentController {


    @Autowired
    private IBookContentService bookContentService;

    /**
     * 查询小说正文
     */
    @GetMapping("/content")
    public Result<BookContentVo> bookContent(BookContentParam param, HttpServletRequest request) {
        BookContentVo bookContentVo = bookContentService.bookContent(param,request);
        return Result.success(bookContentVo);
    }

}
